<?php

// 获取一键融资列表
// GET project.cxlist

namespace app\api\resource\project;
use think\Db;
use think\Session;

class Cxlist
{
    // 方法
    public $_method = ['GET'];
    // 前置
    public $_pre    = ['login','isCyz'];
    // 描述
    public $_description = '获取一键融资列表';
    // 参数
    public $_param  = [
    ];
    // 返回
    public $_return = [
        200 => '获取成功',
    ];

    public function run(&$request)
    {
        $memberId = Session::get('member.id');

        $list = Db::name('project')->where('member_id',$memberId)
                                   ->where('delete_time','eq',0)
                                   ->where('is_cp',1)
                                   ->select();
        return [200,$list];
    }
}